<?php

/**
 * LoginForm class.
 * LoginForm is the data structure for keeping
 * user login form data. It is used by the 'login' action of 'SiteController'.
 */
class ForgotPasswdForm extends CFormModel
{
  public $email;
  
    public function rules()
  {
    return array(
      array('email', 'required'),array('email', 'email'));
  }
  
    public function attributeLabels()
  {
    return array(
      'email'=>'登录mail：');
  }
  
  public function findUserByEmail(){
    $user = User::model()->findByAttributes(array('email'=>$this->email));
    return $user;
  }
}
    
?>
  